import {SET_LIGHT_THRESHOLD, SET_SCREEN_OFF} from "./settingReducer";

export interface SettingAction{
  type: string,
  payload: number
}

export const changeLightThreshold = (s: string) => {
  return {
    type: SET_LIGHT_THRESHOLD,
    payload: parseFloat(s)
  };
}

export const changeScreenOff = (s: string) => {
  return {
    type: SET_SCREEN_OFF,
    payload: parseFloat(s)
  };
}
